<template>
  <div class="box">
    <ul>
      <li v-for="(e,i) in list" class="box_item" :key="i" @click="itemClick(e)">
        <div>
          {{e.county}}-{{e.town}}
        </div>
        <div>
          <i class="icon iconfont icon-fanhui-copy"></i>
        </div>
      </li>
    </ul>
  </div>
</template>
<script>
  let echarts = require("echarts");
  import taskApi from "../../requestApi/taskApi";
  import dateModel from "../../components/Module/dateModel";
  import {
    Toast
  } from "mint-ui";
  export default {
    components: {
      dateModel
    },
    data() {
      return {
        list: []
      };
    },
    created: function () {},
    mounted() {
      let self = this;

      self.baseUserMessageDistributeFun();
      window.getAppgetUserToken = function (val) {
        self.baseUserInfoFun(val);
        self.listFun();
      };
      self.titleFun({
        title: "标准化数据"
      });
    },
    methods: {
      itemClick(e) {
        this.basePushFun(`/biaozhunhuashuju/map?id=${e.id}&town=${e.town}`);
      },
      async listFun() {
        let self = this;
        let params = {};
        let res = await taskApi.GetApistatisticsareatree(params);
        if (res.statusCode == 200) {
          self.list = res.data.child;
        } else {
          Toast({
            message: res.statusMessage,
            position: "bottom"
          });
        }
      }
    },
    filters: {},
    watch: {},
    computed: {}
  };

</script>
<style scoped>
  .box_item {
    height: 44px;
    line-height: 44px;
    border-bottom: 1px solid #ccc;
    padding-left: 12px;
    color: #333;
    font-size: 14px;
    display: flex;
    justify-content: space-between;
    padding-right: 15px;
  }

  .box {
    background: #f6f6f6;
    overflow: hidden;
    width: 100%;
    height: 100vh;
    overflow-y: scroll;
  }

</style>
